package cn.itsource.pet.controller;

import cn.itsource.basic.util.AjaxResult;
import cn.itsource.pet.service.IPetTypeService;
import io.swagger.annotations.Api;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * 宠物类型控制器
 */
@RestController
@Api(tags = "宠物类型宠物类型管理", description = "")
@RequestMapping("/petType")
public class PetTypeController {

    @Autowired
    private IPetTypeService petTypeService;

    /**
     * 获取无限极的宠物类型
     * @return
     */
    @GetMapping("/tree")
    public AjaxResult petTypeTree(){

        return petTypeService.petTypeTree();

    }


}
